import java.util.Scanner;

public class Selflearn_9 {
    public static void main(String[] args){
        int factor=1,i,number;
        Scanner in=new Scanner(System.in);
        number=in.nextInt();
        for (i=1;i<=number;i++)
        {
            factor=factor*i;
        }
        System.out.println(factor);
    }
}
